/*
 * libcpu: arm_types.h
 *
 * the register file
 */

typedef struct {
	union {
		struct {
			uint32_t r0;
			uint32_t r1;
			uint32_t r2;
			uint32_t r3;
			uint32_t r4;
			uint32_t r5;
			uint32_t r6;
			uint32_t r7;
			uint32_t r8;
			uint32_t r9;
			uint32_t r10;
			uint32_t r11;
			uint32_t r12;
			uint32_t r13;
			uint32_t r14;
			uint32_t r15; /* would be PC, but we store PC externally, so this is unused */
			uint32_t cpsr;
		};
		uint32_t r[17];
	};
	uint32_t pc;
} reg_arm_t;

typedef struct {
	Value* ptr_N;
	Value* ptr_Z;
	Value* ptr_C;
	Value* ptr_V;
	Value* ptr_I;
} ccarm_t;

#define ptr_N	cpu->ptr_N
#define ptr_Z	cpu->ptr_Z
#define ptr_C	cpu->ptr_C
#define ptr_V	cpu->ptr_V
#define ptr_I 	cpu->ptr_I
#define ptr_T   cpu->ptr_T

